package com.mmall.service;

import com.mmall.common.ServerResponse;
import com.mmall.pojo.User;

/**
 * Created by root on 3/18/18.
 */
public interface IUserService {

    public ServerResponse<User> login(String userName, String password);

    public ServerResponse register(User user);

    public ServerResponse validCheck(String value, String type);

    public ServerResponse selectQuestion(String userName);

    public ServerResponse forgetCheckAnswer(String username, String question, String answer);

    public ServerResponse<String> forgetResetPassword(String username, String newPsw, String forgetToken);

    public ServerResponse resetPassword(User user, String passwordOld, String passwordNew);

    public ServerResponse updateUserInfo(User userInfo);

    public ServerResponse getUserById(Integer userId);

    public ServerResponse isAdmin(User user);
}
